/*
                     ---   PROPRIETARY NOTICE   ---


     The information contained herein is proprietary to Smiths Aerospace
     and shall not be reproduced or disclosed in whole or in part or used
     for any design or manufacture except when such user possesses direct
     written authorization from Smiths Aerospace.


     Software Common Operating Environment (SCOE)
     Copyright 2006, Smiths Aerospace.

  ------------------------------------------------------------------------------
  %PCMS_HEADER_SUBSTITUTION_START%
   MODULE : %PM%

   HISTORY:
    %PL%

  %PCMS_HEADER_SUBSTITUTION_END%
  ------------------------------------------------------------------------------
*/

/* DESCRIPTION:
 *  This file contains the basic structures and constants required to interact
 *  with the RDC.  Sample structures are provided for an RDC Discrete
 *  Input template (# 13023) and for an RDC discrete output template (# 11022)
 *  These basic structures must be combined with the provided D6-16Z002-01 
 *  header structures to process RDC messages.  See the D6-16Z002-01 document
 *  for more information on how to correctly use these structures.
 */

#ifndef __INCLUDE_RDC_DATASTRUCTS_H__
#define __INCLUDE_RDC_DATASTRUCTS_H__

#define FS_NO_DATA 0x00
#define FS_NORMAL_OPERATION 0x03
#define FS_FUNCTIONAL_TEST 0x0C
#define FS_NO_COMPUTED_DATA 0x30

#define MESSAGE_RESERVED_CONSTANT 0x00000000

/* The following data structures were generated based on D6-16Z002-01:
 * "787 Data Payload Format Requirements", Revision A
 */
 
 
/* Structure for Functional Status Bytes, as described by D6-16Z002-01 */
typedef struct D616Z002_MESSAGE_FSS_STRUCT
{
    UINT8 FS1;
    UINT8 FS2;
    UINT8 FS3;
    UINT8 FS4;
} MESSAGE_FSS_TYPE;


/* Structure for Reserved Word, as described by D6-16Z002-01 */
typedef struct D616Z002_MESSAGE_RESERVED_STRUCT            
{
    UINT32 RESERVED;
} MESSAGE_RESERVED_TYPE;

/* The following data structures were generated based on SDD14551-1:
 *  "RDC I/O Catalogue"
 */

/* Structure for payloads conforming to RDC Template 13000 (discrete input) */
typedef struct RDC_TEMPLATE_13023_STRUCT
{
    UINT32 BITS;
} RDC_DISCRETE_INPUT_TYPE;

/* Structure for payloads conforming to RDC Template 11022 (discrete output) command structure */
typedef struct RDC_TEMPLATE_11022_COMMAND_STRUCT
{
    UINT32 BITS;
} RDC_DISCRETE_OUTPUT_COMMAND_TYPE;

/* Structure for payloads conforming to RDC Template 11022 (discrete output) response structure */
typedef struct RDC_TEMPLATE_11022_RESPONSE_STRUCT
{
    UINT16 PAD;
    UINT16 VOLTS;
    UINT32 OPEN;
    UINT32 GROUND;
    UINT32 STATE;
} RDC_DISCRETE_OUTPUT_RESPONSE_TYPE;

#endif
